/*
 * Copyright © 2015 Cask Data, Inc.
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
 * use this file except in compliance with the License. You may obtain a copy of
 * the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 * License for the specific language governing permissions and limitations under
 * the License.
 */

@import "../../styles/variables.less";
@import "../../../bower_components/bootstrap/less/mixins.less";
@import "../../styles/themes/cdap/mixins.less";

body.state-dashboard {

  .widget {
    background-color: transparent;
    border: 0;
    .panel-heading {
      text-align: center;
      .dropdown {
        color: white;
        font-size: 16px;
        position: absolute;
        top: 10px;
        left: 15px;

        &.open {
          .btn.dropdown-toggle {
            background-color: @cdap-header;
            color: white;
            .border-radius(8px 8px 0 0);
            + .dropdown-menu {
              top: 24px !important;
              left: 1px !important;
              .border-radius(0);
              > li:first-child a { .border-radius(0 4px 0 0); }
              > li:last-child a { .border-radius(0 0 4px 4px); }
            }
          }
        }
        .dropdown-toggle {
          padding: 0 5px 5px;
          span { vertical-align: bottom; }
          .dropdown-defaults();
          .dropdown-blue();
        }
      }
      > span {
        max-width: 60%;
        text-overflow: ellipsis;
        overflow: hidden;
        vertical-align: middle;
      }
    }
    .panel-body {
      background-color: white;
      overflow-x: scroll;
      .border-radius(0 0 8px 8px);
    }
    .panel-footer dl {
      margin: 0;
      white-space: nowrap;
      dt {
        float: left;
        clear: left;
        min-width: 70px;
        &:after { content: ':\00a0'; }
      }
      dd {
        overflow: hidden;
        text-overflow: ellipsis;
      }
    }
  }
  .select-wrapper {
    .border-radius(4px);
    .select-wrapper();
  }

  my-metric-picker {
    .tooltip.tooltip-info {
      z-index: 1020; // lower z-index than modal

      .tooltip-inner {
        background-color: #ffffff;
        color: #333333;
        border: none;
      }

      .tooltip-arrow {
        border-right-color: #ffffff;
      }
    }
  }
}
